﻿using MeetingRoomBooking.Domain.Entities;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;

namespace MeetingRoomBooking.Infrastructure.Data.Configurations;

public class UserConfiguration : IEntityTypeConfiguration<User>
{
    public void Configure(EntityTypeBuilder<User> builder)
    {
        builder.Property(t => t.UserName).HasMaxLength(200).IsRequired();
        builder.HasKey(t => t.Id);
        builder.Property(t => t.Role);
        builder.Property(t => t.Password);
        builder.Property(t => t.Email);
    }
}
